//
//  NYDetailQuestionViewController.m
//  NiuWaJiaoYu
//
//  Created by MinLison on 2018/1/10.
//  Copyright © 2018年 niuwaketang. All rights reserved.
//

#import "NYDetailQuestionViewController.h"

@interface NYDetailQuestionViewController ()

@end

@implementation NYDetailQuestionViewController
- (void)setDetailModel:(NYCourseModel *)detailModel
{
        _detailModel = detailModel;
        [self loadData];
}
- (void)viewDidLoad
{
        [super viewDidLoad];
        [self loadData];
}
- (void)loadData
{
        if (self.isViewLoaded)
        {
                [self configNimbus];
                if (self.detailModel.message.count <= 0) {
                        [self hideEmptyView];
                        [self showEmptyViewWithText:@"暂无问答" detailText:@"" buttonTitle:nil buttonAction:nil];
                } else {
                        [self.tableViewModel addObjectsFromArray:self.detailModel.message];
                        [self.tableView reloadData];
                }
        }
}
- (void)configNimbus
{
        [super configNimbus];
}

@end
